﻿using System;
using System.Collections.Generic;
using System.Text;
using ATSModel;
using ATSIDAL;
using System.Data;

namespace ATSBLL
{
    public class Report_ElecBatchData 
    {
        private static readonly IElecBatchReport dal = DALFactory.DataAccess.CreateElecBatchReport();

        // 根据条码获取电性能数据
        public DataSet ElecData_ByProSN(string TableName, string ProSN)
        {
            return dal.ElecData_ByProSN(TableName, ProSN);
        }

        // 根据产品型号获取电性能数据
        public DataSet ElecData_ByProTypeID(string TableName, string ProTypeID)
        {
            return dal.ElecData_ByProTypeID(TableName, ProTypeID);
        } 

        // 根据MO号获取电性能数据
        public DataSet ElecData_ByMO(string TableName, string MOID)
        {
            return dal.ElecData_ByMO(TableName, MOID);
        } 
        //根据MO与时间段检索
        public DataSet ELData_ByMOandDte(string TableName, string MOID, string sDt, string eDt)
        {
            return dal.ELData_ByMOandDte(TableName, MOID, sDt, eDt);
        }
        ///根据测试人员与测试时间段检索
        public DataSet ELData_ByUserIDandDte(string TableName, string UserID, string sDt, string eDt)
        {
            return dal.ELData_ByUserIDandDte(TableName,UserID, sDt, eDt);
        }

        /// <summary>
        /// 根据时间段检索
        /// </summary>
        /// <param name="sDt"></param>
        /// <param name="eDt"></param>
        /// <returns></returns>
        public DataSet ELData_ByDte(string TableName, string sDt, string eDt) 
        {
            return dal.ELData_ByDte(TableName,sDt, eDt);
        }

        // 根据MO号获取电性能数据
        public DataSet ElecData_ByMOS(string TableName, string MOID)
        {
            return dal.ElecData_ByMOS(TableName, MOID);
        }

        // 根据条码获取电性能数据
        public DataSet ElecData_ByProSNS(string TableName, string ProSN)
        {
            return dal.ElecData_ByProSNS(TableName, ProSN);
        }

        // 根据产品型号获取电性能数据
        public DataSet ElecData_ByProTypeIDS(string TableName, string ProTypeID)
        {
            return dal.ElecData_ByProTypeIDS(TableName, ProTypeID);
        } 
        public DataSet ELData_ByMOandDteS(string TableName, string MOID, string sDt, string eDt)
        {
            return dal.ELData_ByMOandDteS(TableName, MOID, sDt, eDt);
        }

        ///根据测试人员与测试时间段检索
        public DataSet ELData_ByUserAndDteS(string TableName,string UserID, string sDt, string eDt)
        {
            return dal.ELData_ByUserAndDteS(TableName,UserID, sDt, eDt);
        }

        /// <summary>
        /// 根据时间段检索
        /// </summary>
        /// <param name="sDt"></param>
        /// <param name="eDt"></param>
        /// <returns></returns>
        public DataSet ELData_ByDtes(string TableName, string sDt, string eDt)
        {
            return dal.ELData_ByDte(TableName,sDt, eDt);
        }
    }

}
